package com.gitee.yannzh.rune.support.crud;

import com.gitee.yannzh.rune.support.crud.model.ViewModel;

import java.util.HashMap;
import java.util.Map;

/**
 * @author Yann
 * @date 2025/4/21 13:36
 * @description
 * @since 1.0.0
 */
public class ViewContext {


    private static final Map<String, ViewModel> VIEW_CACHE = new HashMap<>();


    public static ViewModel getViewModel(String viewName) {
        return VIEW_CACHE.get(viewName);
    }

    protected static void putViewModel(String viewName, ViewModel viewModel) {
        VIEW_CACHE.put(viewName, viewModel);
    }


}
